package cn.jobstart.searchExt;

import cn.jobstart.model.Job;
import cn.jobstart.search.JobSearch;
import io.swagger.annotations.ApiModel;
import lombok.Data;
import lombok.experimental.Accessors;


/**
 * @author sunke
 * @Date 2023-09-15 14:55:16
 * @description JobSearchExt      职位名称
 */
@Data
@Accessors(chain = true)
@ApiModel("职位名称JobSearchExt")
public class JobSearchExt extends JobSearch<JobSearchExt> {
    private String upNameLike;
    private int topFlag = -1;

    public static JobSearchExt getInstance() {
        return new JobSearchExt();
    }

    public JobSearchExt setUpNameLike(String upNameLike) {
        this.upNameLike = upNameLike;
        setLikeField("up_job.j_name", upNameLike);
        return this;
    }

    public JobSearchExt setTopFlag(int topFlag) {
        this.topFlag = topFlag;
        if (topFlag == 1) {

            this.setFieldNull(Job.UP_ID);
        }

        return this;
    }

    @Override
    public JobSearchExt getSubThis() {
        return this;
    }

}

